package com.wolfman.uploadfile.service;

import com.wolfman.uploadfile.po.FileUpload;

import java.util.List;

/**
 * @Title
 * @Description
 * @Author WolfMan
 * @Date 2021/8/23 13:54
 * @Email 2370032534@qq.com
 */
public interface FileUploadService {
    /**
     * 更新文件信息
     *
     * @param fileUpload
     */
    void insertOne(FileUpload fileUpload);

    /**
     * 更新进度
     *
     * @param fileUpload
     */
    void updateProcess(FileUpload fileUpload);

    /**
     * 查询文件信息
     *
     * @param fileUpload
     * @return
     */
    FileUpload selectById(FileUpload fileUpload);

    /**
     * 根据id查找进度
     * @param fileUpload
     * @return
     */
    Double selectProcessById(FileUpload fileUpload);

    /**
     * 查找所有未完成的列表
     * @return
     */
    List<FileUpload> selectAllUnfinished();

    /**
     * 根据id删除一条记录
     * @param f
     */
    void deleteById(FileUpload f);
}
